* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f5f5f7;
}

.container {
    background: white;
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    width: 90%;
    max-width: 400px;
}

.timer {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-bottom: 2rem;
}

input {
    width: 60px;
    height: 50px;
    font-size: 20px;
    text-align: center;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    outline: none;
    transition: border-color 0.3s;
}

input:focus {
    border-color: #0071e3;
}

.colon {
    font-size: 24px;
    font-weight: bold;
}

.display {
    text-align: center;
    font-size: 48px;
    font-weight: bold;
    margin-bottom: 2rem;
    color: #1d1d1f;
}

.buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.btn {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 10px 20px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
    background: #0071e3;
    color: white;
}

.btn:disabled {
    background: #999;
    cursor: not-allowed;
}

.btn:not(:disabled):hover {
    background: #0077ed;
    transform: translateY(-1px);
}

.icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* 为输入框添加移动端样式优化 */
@media (max-width: 480px) {
    input {
        width: 45px;
        height: 40px;
        font-size: 16px;
    }
    
    .display {
        font-size: 28px;
    }
    
    .colon {
        font-size: 20px;
    }
}

/* 历史记录样式 */
.history-section {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e0e0e0;
}

.history-title {
    font-size: 1.1rem;
    color: #1d1d1f;
    margin-bottom: 1rem;
}

.history-list {
    max-height: 200px;
    overflow-y: auto;
    padding-right: 10px;
}

.history-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    margin-bottom: 8px;
    background: #f5f5f7;
    border-radius: 8px;
    font-size: 0.9rem;
    animation: slideIn 0.3s ease;
}

.history-item .time {
    color: #1d1d1f;
    font-weight: 500;
}

.history-item .date {
    color: #666;
    font-size: 0.8rem;
}

.history-item .delete-btn {
    background: none;
    border: none;
    color: #ff3b30;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    opacity: 0;
    transition: opacity 0.2s;
}

.history-item:hover .delete-btn {
    opacity: 1;
}

@keyframes slideIn {
    from {
        transform: translateY(-10px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* 自定义滚动条样式 */
.history-list::-webkit-scrollbar {
    width: 6px;
}

.history-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.history-list::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.history-list::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
} 